import { get, post,del } from '../utils/request'

// 保存主题文件
export const postSaveTopicFile = (params) => {
  return post('/topic/file/saveFile', params)
}

// 获取主题文件列表
export const getTopicFileList = (topicId, page = 1, limit = 10) => {
  return get(`/topic/file/list/${topicId}`, { page, limit })
}

// 删除主题文件
export const deleteTopicFile = (fileId) => {
  return del(`/topic/file/delete/${fileId}`, { fileId })
}

// 获取主题附件列表（用于展示）
export const getTopicAttachmentList = (topicId, page = 1, limit = 10) => {
  return get(`/topic/file/list/${topicId}`, { page, limit })
} 